package com.flowerSystem.service.impl;

import com.flowerSystem.entity.Collection;
import com.flowerSystem.entity.Productinformation;
import com.flowerSystem.mapper.CollectionMapper;
import com.flowerSystem.service.CollectionService;
import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;

import java.util.List;

/**
 * <p>
 *  服务实现类
 * </p>
 *
 * @author 鲜花遇上牛战士
 * @since 2023-08-28
 */
@Service
public class CollectionServiceImpl extends ServiceImpl<CollectionMapper, Collection> implements CollectionService {
    @Autowired
    CollectionMapper collectionMapper;
    @Override
    public List<Productinformation> getCollectionByUser(int user_id) {
        return collectionMapper.getCollectionByUser(user_id);
    }

    @Override
    public boolean getUserCollection(int userId,int productinformationId) {

        collectionMapper.getUserCollection(userId,productinformationId);
        return false;
    }
}
